import request from '@/utils/request'

// 首页
export const fetchLastChapter = (params) => {
    return request.get('/user-grammar/grammar-info', {params})
}

//获取详情
export const fetchChapterList = (params) => {
    return request.get('/user-grammar/grammar-course', {params})
}


//
export const grammarList = (params) => {
    return request.get('/user-grammar/grammar-list', {params})
}
export const grammarInfoCheck = (params) => {
    return request.put('/user-grammar/grammar-info-check', params)
}
export const grammarDetail = (params) => {
    return request.get('/user-grammar/detail', {params})
}

export const getFetchManual = (params) => {
    return request.get('/user-grammar/color-list', {params})
}
export const getStart = (params) => {
    return request.get('/user-grammar/Start', {params})
}
export const getStudyOver = (params) => {
    return request.put('/user-grammar/StudyOver', params)
}
export const getColorOver = (params) => {
    return request.put('/user-grammar/color-over', params)
}

export const grammarCourseDay = (params) => {
    return request.get('/user-grammar/grammar-course-day', {params})
}
export const grammarCourseAll = (params) => {
    return request.get('/user-grammar/grammar-course-all', {params})
}
export const grammarCourseVocabulary = (params) => {
    return request.get('/user-grammar/grammar-course-vocabulary', {params})
}
export const grammarPractice = (params) => {
    return request.get('/user-grammar/grammar-practice', {params})
}
export const putGrammarPractice = (params) => {
    return request.put('/user-grammar/grammar-practice', params)
}
export const grammarPracticeResult = (params) => {
    return request.get('/user-grammar/grammar-practice-result', {params})
}
export const checkWord = (params) => {
    return request.get('/article-word/translate', {params})
}

// 写作首页
export const writingInfo = (params) => {
    return request.get('/user-writing/writing-info', {params})
}
// 获取学员开通的课程
export const writingCourse = (params) => {
    return request.get('/user-writing/writing-course', {params})
}
export const checkCourse = (params) => {
    return request.get('/user-writing/check-course', {params})
}

export const writingModelList = (params) => {
    return request.get('/user-writing/writing-model-list', {params})
}

export const writingCourseInfo = (params) => {
    return request.get('/user-writing/writing-course-info', {params})
}

export const progressSet = (params) => {
    return request.get('/user-writing/progress-set', {params})
}

export const writingMode = (params) => {
    return request.get('/user-writing/writing-mode', {params})
}
export const userRecorList = (params) => {
    return request.get('/user-writing/user-recor-list', {params})
}

export const createQrcode = (params) => {
    return request.get('/user-writing/qrcode', {params})
}

export const cosTempSecret = (params) => {
    return request.get('/user-writing/cos-temp-secret', {params})
}
export const writingImgUp = (params) => {
    return request.get('/user-writing/writing-img-up', {params})
}

export const writingImg = (params) => {
    return request.get('/user-writing/writing-img', {params})
}

export const userCourseOver = (params) => {
    return request.get('/user-writing/user-course-over', {params})
}